<template>
  <img tabindex="0" class="like-btn" :src="imagePath" />
</template>

<script type="text/babel">
  import AssetComponent from './AssetComponent'
  import { Asset } from '../../libs/AssetsManager'

  export default {
    mixins: [ AssetComponent ],
    data () {
      return {
        imagePath: ''
      }
    },
    props: {
      asset: {
        type: Asset
      }
    },
    ready: function () {
      this.imagePath = this.asset.currentState()
    },
    methods: {
      onAssetStateChanged: function (asset, currentState) {
        this.imagePath = currentState
      }
    }
  }
</script>

<style scoped>
  .like-btn {
  }
</style>